function isActive=checkLastUpdate(logFile,Duration)

if isfile(logFile)
    flinfo=dir(logFile);
    isActive=~((datetime('now')-datetime(flinfo.date))>seconds(Duration));
else
    isActive=0;
end
end